// 更多跟帖
<template>
  <div>
      <headerMiddle title='更多跟贴' /> 
      <comment  v-for="(item,index) in comments" :key="index"
      :commentItem="item"
      />
  </div>
</template>

<script>
import headerMiddle from "../components/headerMiddle";
import comment from "../components/comment";
export default {
  components: {
    headerMiddle,
    comment
  },
  data(){
      return{
          postId:this.$route.params.id,
          comments:[]
      }
  },
  mounted(){
      this.$axios({
          url:'/post_comment/'+this.postId,
          method:'get'
      }).then(res=>{
          const {data} = res.data;
          this.comments = data
      })
  }
};
</script>

<style>
</style>